# 指定基础镜像
FROM alpine:latest
RUN echo "https://mirror.tuna.tsinghua.edu.cn/alpine/v3.4/main/" > /etc/apk/repositories
# 镜像中安装git客户端
RUN apk update \
&& apk upgrade \
&& apk add --no-cache bash git openssh \
&& rm -rf /var/cache/apk/*
# RUN apk add --no-cache git
# 将功能脚本文件添加或拷贝到镜像中
ADD script/zzh.sh /usr/local/bin/
# 执行脚本(指令)
ENTRYPOINT ["sh"]
CMD ["/usr/local/bin/zzh.sh"]
